<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Title</title>
</head>
<body>

<script>
// 1.参数问题：放入两个参数
  const sum = (num1,num2) => {
    return num1+num2
  }
// 2.参数问题：放入一个参数,可以省略()
  const power= num => {
    return num*num
  }
// 3. 函数代码块中有多行代码
  const aaa = () => {
    console.log('四季花常在');
    console.log('九州事尽知');
  }
// 4.函数代码块中只有一行代码,不用写{}和return，会直接把代码结果返回
const mul = (num1,num2) => num1*num2
const demo = () => console.log('愿君为星我为月') //愿君为星我为月
console.log(demo()); // undefined

</script>
</body>
</html>